# -*- coding: utf-8 -*-
# @Time        :2025/4/17 10:01
# @Author      :文刀水寿
# @File        : app.py
"""
 @Description :
"""
from fastapi import FastAPI
from fastapi.staticfiles import StaticFiles
import uvicorn
from Apps.app1.urls import user
from Apps.app2.urls import app2
from Apps.app3.urls import app3
from Apps.app4.urls import app4
from Apps.app5.urls import app5
from Apps.app6.urls import app6
from Apps.app8.urls import app8


app = FastAPI()

# mount 方法：
# app.mount 是 FastAPI 提供的一个方法，用于将一个子应用挂载到主应用的某个路径下。
# 这里的路径是 "/static"，表示所有以 /static 开头的请求都会被转发到挂载的子应用。
app.mount("/static", StaticFiles(directory="static"))

app.include_router(user, prefix="/user", tags=["app1路径参数"])
app.include_router(app2, prefix="/user", tags=["app2查询参数"])
app.include_router(app3, prefix="/app3", tags=["app3请求体数据"])
app.include_router(app4, prefix="/app4", tags=["app4form数据"])
app.include_router(app5, prefix="/app5", tags=["app5文件上传"])
app.include_router(app6, prefix="/app6", tags=["app6Request对象"])
app.include_router(app8, prefix="/app8", tags=["app8响应模型相关参数"])



if __name__ == '__main__':
    uvicorn.run("app:app",
                reload=True,
                port=8080)